package com.itqf.utils;

import com.itqf.enums.Rexum;
import com.itqf.vo.ResultVo;

/**
 * 作者:高少东
 * 项目名:  product_gsd
 * 时间: 2019/12/18 21:43
 * 描述:
 */

public class R {


    public static ResultVo ok(){

        return  new ResultVo(0,"成功",null);
    }


    public static  ResultVo ok(Object data){

        return  new ResultVo(0,"成功",data);
    }


    public static ResultVo error(Integer code,String msg){


        return  new ResultVo(code,msg,null);
    }

    public static ResultVo error(Rexum rexum){

        return  new ResultVo(rexum.getCode(),rexum.getMsg(),null);
    }
}
